//
//  Database.h
//  XDD
//
//  Created by mao on 12/10/14.
//  Copyright (c) 2014 yuhaya. All rights reserved.
//

#import <Foundation/Foundation.h>

@interface Database : NSObject
{
    FMDatabaseQueue * queue;
    FMDatabase * datadb;
}
+ (id)sharedDatabase;
-(void) demoData;
-(void) insertData:(NSMutableArray *)data table:(NSString *)table data:(NSDictionary *)data;
-(NSMutableArray *) studentPointByDay:(NSString *)day andStuId:(NSString *)stuid;
-(NSMutableArray *) studentPointByDataId:(NSString *)data_id;
-(NSMutableArray *) weekPoint:(NSMutableArray *)days andStuId:(NSString *) stuid;
-(void) syncData;
-(void) syncSchool;
-(NSMutableArray *) getSchools;
-(NSMutableArray *) genStudents:(NSString *)gen_id;
- (void) syncStudents:(NSString *)user_id;
@end
